package com.petmall.cart.service;

import com.petmall.cart.vo.CartItemVo;
import com.petmall.cart.vo.CartVo;

import java.util.List;
import java.util.concurrent.ExecutionException;

/**
 * @author liang zai
 * @date 2022/4/15 15:00
 * @description
 */
public interface CartService {
    //添加购物车
    CartItemVo addToCart(Long skuId, Integer num) throws ExecutionException, InterruptedException;
    //获取购物车信息
    CartItemVo getCartItem(Long skuId);

    CartVo getCart() throws ExecutionException, InterruptedException;

    void checkItem(Long skuId, Integer check);

    void countItem(Long skuId, Integer num);

    void deleteItem(Long skuId);

    List<CartItemVo> getCheckItems() throws ExecutionException, InterruptedException;
}

